
public class Pet2 {


 private String name;
private String type;
private String color;
 public void Pet(){
	name = "Spike";
	type = "dog";
	color = "black";
}
	
 public void Pet (String n){
	name=n;
	type="dog";
	color="black";
}
 public void Pet(String n,String t, String c){
	name = n;
	type=t;
	color=c;
}
void setName(String n){
	if (n.length()<= 6){
		name=n;
		
	}else{
		name = n.substring(0,5);
	}
}
String getName(){
	return name;
}
	}


